<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.15"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>QuantumLibrary: Bloomberg::quantum::ICoroPromise&lt; PROMISE, T &gt; Interface Template Reference</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../jquery.js"></script>
<script type="text/javascript" src="../../dynsections.js"></script>
<link href="../../navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../resize.js"></script>
<script type="text/javascript" src="../../navtreedata.js"></script>
<script type="text/javascript" src="../../navtree.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  $(document).ready(initResizable);
/* @license-end */</script>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../search/searchdata.js"></script>
<script type="text/javascript" src="../../search/search.js"></script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">QuantumLibrary
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.15 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="../../menudata.js"></script>
<script type="text/javascript" src="../../menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('../../',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html','../../');});
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="../../d3/dda/structBloomberg_1_1quantum_1_1ICoroPromise-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">Bloomberg::quantum::ICoroPromise&lt; PROMISE, T &gt; Interface Template Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div>  </div>
</div><!--header-->
<div class="contents">

<p>Exposes methods to access and manipulate a coroutine-compatible promise.  
 <a href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="../../d5/da1/quantum__icoro__promise_8h_source.html">quantum_icoro_promise.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for Bloomberg::quantum::ICoroPromise&lt; PROMISE, T &gt;:</div>
<div class="dyncontent">
 <div class="center">
  <img src="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.png" usemap="#Bloomberg::quantum::ICoroPromise_3C_20PROMISE_2C_20T_20_3E_map" alt=""/>
  <map id="Bloomberg::quantum::ICoroPromise_3C_20PROMISE_2C_20T_20_3E_map" name="Bloomberg::quantum::ICoroPromise_3C_20PROMISE_2C_20T_20_3E_map">
<area href="../../db/db8/structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom.html" alt="Bloomberg::quantum::Traits::DerivedFrom&lt; PROMISE&lt; T &gt;, ICoroPromise&lt; PROMISE, T &gt;, IPromiseBase &gt;" shape="rect" coords="0,0,618,24"/>
  </map>
</div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:a4f8f9f1d242c351ffb21743e668f8cd9"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a4f8f9f1d242c351ffb21743e668f8cd9">ContextTag</a> = <a class="el" href="../../dd/d45/structBloomberg_1_1quantum_1_1CoroContextTag.html">CoroContextTag</a></td></tr>
<tr class="separator:a4f8f9f1d242c351ffb21743e668f8cd9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a47c0bcd8812fab42118f7c987d9ae89a"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a47c0bcd8812fab42118f7c987d9ae89a">Ptr</a> = std::shared_ptr&lt; <a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">ICoroPromise</a>&lt; PROMISE, T &gt; &gt;</td></tr>
<tr class="separator:a47c0bcd8812fab42118f7c987d9ae89a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8258db46a62ca4439bacd5a0c5ddf1a9"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a8258db46a62ca4439bacd5a0c5ddf1a9">Impl</a> = PROMISE&lt; T &gt;</td></tr>
<tr class="separator:a8258db46a62ca4439bacd5a0c5ddf1a9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a63eea5b5603a5b215a927889143ad69d"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a63eea5b5603a5b215a927889143ad69d">ICoroPromise</a> (<a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a8258db46a62ca4439bacd5a0c5ddf1a9">Impl</a> *derived)</td></tr>
<tr class="memdesc:a63eea5b5603a5b215a927889143ad69d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor.  <a href="#a63eea5b5603a5b215a927889143ad69d">More...</a><br /></td></tr>
<tr class="separator:a63eea5b5603a5b215a927889143ad69d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2ad0c521263cddf365c3000c5a01e614"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="../../dc/d48/namespaceBloomberg_1_1quantum.html#a294434a555befbec5230f5ff03944878">CoroFuturePtr</a>&lt; T &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a2ad0c521263cddf365c3000c5a01e614">getICoroFuture</a> () const =0</td></tr>
<tr class="memdesc:a2ad0c521263cddf365c3000c5a01e614"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the associated coroutine future.  <a href="#a2ad0c521263cddf365c3000c5a01e614">More...</a><br /></td></tr>
<tr class="separator:a2ad0c521263cddf365c3000c5a01e614"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a962692a27f424841f5fc00ede4e6aa56"><td class="memTemplParams" colspan="2">template&lt;class V , class  = NonBufferType&lt;T,V&gt;&gt; </td></tr>
<tr class="memitem:a962692a27f424841f5fc00ede4e6aa56"><td class="memTemplItemLeft" align="right" valign="top">int&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a962692a27f424841f5fc00ede4e6aa56">set</a> (<a class="el" href="../../d3/d63/structBloomberg_1_1quantum_1_1ICoroSync.html#a109b2c4b7d70d53d48bb640a9d849b29">ICoroSync::Ptr</a> sync, V &amp;&amp;value)</td></tr>
<tr class="memdesc:a962692a27f424841f5fc00ede4e6aa56"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the promised value.  <a href="#a962692a27f424841f5fc00ede4e6aa56">More...</a><br /></td></tr>
<tr class="separator:a962692a27f424841f5fc00ede4e6aa56"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad6b20a026f8e96948fdf06a87f20bf7c"><td class="memTemplParams" colspan="2">template&lt;class V , class  = BufferType&lt;T,V&gt;&gt; </td></tr>
<tr class="memitem:ad6b20a026f8e96948fdf06a87f20bf7c"><td class="memTemplItemLeft" align="right" valign="top">void&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#ad6b20a026f8e96948fdf06a87f20bf7c">push</a> (<a class="el" href="../../d3/d63/structBloomberg_1_1quantum_1_1ICoroSync.html#a109b2c4b7d70d53d48bb640a9d849b29">ICoroSync::Ptr</a> sync, V &amp;&amp;value)</td></tr>
<tr class="memdesc:ad6b20a026f8e96948fdf06a87f20bf7c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Push a single value into the promise buffer.  <a href="#ad6b20a026f8e96948fdf06a87f20bf7c">More...</a><br /></td></tr>
<tr class="separator:ad6b20a026f8e96948fdf06a87f20bf7c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3b0b76678c43404f0797da0105ec7b7f"><td class="memTemplParams" colspan="2">template&lt;class V  = T, class  = BufferRetType&lt;V&gt;&gt; </td></tr>
<tr class="memitem:a3b0b76678c43404f0797da0105ec7b7f"><td class="memTemplItemLeft" align="right" valign="top">int&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a3b0b76678c43404f0797da0105ec7b7f">closeBuffer</a> ()</td></tr>
<tr class="memdesc:a3b0b76678c43404f0797da0105ec7b7f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Close a promise buffer.  <a href="#a3b0b76678c43404f0797da0105ec7b7f">More...</a><br /></td></tr>
<tr class="separator:a3b0b76678c43404f0797da0105ec7b7f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="inherit_header pub_methods_structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom')"><img src="../../closed.png" alt="-"/>&#160;Public Member Functions inherited from <a class="el" href="../../db/db8/structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom.html">Bloomberg::quantum::Traits::DerivedFrom&lt; PROMISE&lt; T &gt;, ICoroPromise&lt; PROMISE, T &gt;, IPromiseBase &gt;</a></td></tr>
<tr class="memitem:a58de90b9397ea0c48c3cbe37866ddb3d inherit pub_methods_structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/db8/structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom.html#a58de90b9397ea0c48c3cbe37866ddb3d">~DerivedFrom</a> ()=default</td></tr>
<tr class="separator:a58de90b9397ea0c48c3cbe37866ddb3d inherit pub_methods_structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a488bbb59ef434e73158404132fb73e47 inherit pub_methods_structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/db8/structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom.html#a488bbb59ef434e73158404132fb73e47">operator IPromiseBase *</a> ()</td></tr>
<tr class="separator:a488bbb59ef434e73158404132fb73e47 inherit pub_methods_structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afb49ed2f85e01510de43aa05dc3a4563 inherit pub_methods_structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/db8/structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom.html#afb49ed2f85e01510de43aa05dc3a4563">operator IPromiseBase &amp;</a> ()</td></tr>
<tr class="separator:afb49ed2f85e01510de43aa05dc3a4563 inherit pub_methods_structBloomberg_1_1quantum_1_1Traits_1_1DerivedFrom"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><h3>template&lt;template&lt; class &gt; class PROMISE, class T&gt;<br />
interface Bloomberg::quantum::ICoroPromise&lt; PROMISE, T &gt;</h3>

<p>Exposes methods to access and manipulate a coroutine-compatible promise. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">PROMISE</td><td>The derived promise (concrete type). </td></tr>
    <tr><td class="paramname">T</td><td>The type of value contained in this promise. </td></tr>
  </table>
  </dd>
</dl>
</div><h2 class="groupheader">Member Typedef Documentation</h2>
<a id="a4f8f9f1d242c351ffb21743e668f8cd9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4f8f9f1d242c351ffb21743e668f8cd9">&#9670;&nbsp;</a></span>ContextTag</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;template&lt; class &gt; class PROMISE, class T&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">using <a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">Bloomberg::quantum::ICoroPromise</a>&lt; PROMISE, T &gt;::<a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a4f8f9f1d242c351ffb21743e668f8cd9">ContextTag</a> =  <a class="el" href="../../dd/d45/structBloomberg_1_1quantum_1_1CoroContextTag.html">CoroContextTag</a></td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a id="a8258db46a62ca4439bacd5a0c5ddf1a9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8258db46a62ca4439bacd5a0c5ddf1a9">&#9670;&nbsp;</a></span>Impl</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;template&lt; class &gt; class PROMISE, class T&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">using <a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">Bloomberg::quantum::ICoroPromise</a>&lt; PROMISE, T &gt;::<a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a8258db46a62ca4439bacd5a0c5ddf1a9">Impl</a> =  PROMISE&lt;T&gt;</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a id="a47c0bcd8812fab42118f7c987d9ae89a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a47c0bcd8812fab42118f7c987d9ae89a">&#9670;&nbsp;</a></span>Ptr</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;template&lt; class &gt; class PROMISE, class T&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">using <a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">Bloomberg::quantum::ICoroPromise</a>&lt; PROMISE, T &gt;::<a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a47c0bcd8812fab42118f7c987d9ae89a">Ptr</a> =  std::shared_ptr&lt;<a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">ICoroPromise</a>&lt;PROMISE, T&gt; &gt;</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a63eea5b5603a5b215a927889143ad69d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a63eea5b5603a5b215a927889143ad69d">&#9670;&nbsp;</a></span>ICoroPromise()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;template&lt; class &gt; class PROMISE, class T&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">Bloomberg::quantum::ICoroPromise</a>&lt; PROMISE, T &gt;::<a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">ICoroPromise</a> </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html#a8258db46a62ca4439bacd5a0c5ddf1a9">Impl</a> *&#160;</td>
          <td class="paramname"><em>derived</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Constructor. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">derived</td><td>A pointer to the concrete implementation of this class. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>The constructor parameter is only used for template deduction at compile time. </dd></dl>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="a3b0b76678c43404f0797da0105ec7b7f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3b0b76678c43404f0797da0105ec7b7f">&#9670;&nbsp;</a></span>closeBuffer()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;template&lt; class &gt; class PROMISE, class T &gt; </div>
<div class="memtemplate">
template&lt;class V , class &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">int <a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">Bloomberg::quantum::ICoroPromise</a>&lt; PROMISE, T &gt;::closeBuffer </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Close a promise buffer. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">BUF</td><td>Represents a class of type <a class="el" href="../../d1/d87/classBloomberg_1_1quantum_1_1Buffer.html" title="Container which allows buffered access to a series of values. Values are pushed-in (written) by a pro...">Buffer</a>. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>Once closed no more Pushes can be made into the buffer. The corresponding future can still Pull values until the buffer is empty. </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success. </dd></dl>

</div>
</div>
<a id="a2ad0c521263cddf365c3000c5a01e614"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2ad0c521263cddf365c3000c5a01e614">&#9670;&nbsp;</a></span>getICoroFuture()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;template&lt; class &gt; class PROMISE, class T&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="../../dc/d48/namespaceBloomberg_1_1quantum.html#a294434a555befbec5230f5ff03944878">CoroFuturePtr</a>&lt;T&gt; <a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">Bloomberg::quantum::ICoroPromise</a>&lt; PROMISE, T &gt;::getICoroFuture </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Get the associated coroutine future. </p>
<dl class="section return"><dt>Returns</dt><dd>An interface to the associated future object sharing a common state. </dd></dl>

<p>Implemented in <a class="el" href="../../d1/d15/classBloomberg_1_1quantum_1_1Promise.html#a774002dc514111f16e550f584dd32f95">Bloomberg::quantum::Promise&lt; T &gt;</a>.</p>

</div>
</div>
<a id="ad6b20a026f8e96948fdf06a87f20bf7c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad6b20a026f8e96948fdf06a87f20bf7c">&#9670;&nbsp;</a></span>push()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;template&lt; class &gt; class PROMISE, class T &gt; </div>
<div class="memtemplate">
template&lt;class V , class &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">Bloomberg::quantum::ICoroPromise</a>&lt; PROMISE, T &gt;::push </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d3/d63/structBloomberg_1_1quantum_1_1ICoroSync.html#a109b2c4b7d70d53d48bb640a9d849b29">ICoroSync::Ptr</a>&#160;</td>
          <td class="paramname"><em>sync</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">V &amp;&amp;&#160;</td>
          <td class="paramname"><em>value</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Push a single value into the promise buffer. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">BUF</td><td>Represents a class of type <a class="el" href="../../d1/d87/classBloomberg_1_1quantum_1_1Buffer.html" title="Container which allows buffered access to a series of values. Values are pushed-in (written) by a pro...">Buffer</a>. </td></tr>
    <tr><td class="paramname">V</td><td>The type of value contained in <a class="el" href="../../d1/d87/classBloomberg_1_1quantum_1_1Buffer.html" title="Container which allows buffered access to a series of values. Values are pushed-in (written) by a pro...">Buffer</a>. </td></tr>
  </table>
  </dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">sync</td><td>A pointer to a coroutine synchronization context. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">value</td><td>Value to push at the end of the buffer. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>Method available for buffered futures only. Once the buffer is closed, no more Push operations are allowed. </dd></dl>

</div>
</div>
<a id="a962692a27f424841f5fc00ede4e6aa56"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a962692a27f424841f5fc00ede4e6aa56">&#9670;&nbsp;</a></span>set()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;template&lt; class &gt; class PROMISE, class T &gt; </div>
<div class="memtemplate">
template&lt;class V , class &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">int <a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">Bloomberg::quantum::ICoroPromise</a>&lt; PROMISE, T &gt;::set </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="../../d3/d63/structBloomberg_1_1quantum_1_1ICoroSync.html#a109b2c4b7d70d53d48bb640a9d849b29">ICoroSync::Ptr</a>&#160;</td>
          <td class="paramname"><em>sync</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">V &amp;&amp;&#160;</td>
          <td class="paramname"><em>value</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Set the promised value. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">V</td><td>The type of the value. Must be implicitly deduced by the compiler and should always be == T. </td></tr>
  </table>
  </dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">sync</td><td>A pointer to a coroutine synchronization context. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">value</td><td>A reference to the value (l-value or r-value). </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success </dd></dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="../../d6/db9/namespaceBloomberg.html">Bloomberg</a></li><li class="navelem"><a class="el" href="../../dc/d48/namespaceBloomberg_1_1quantum.html">quantum</a></li><li class="navelem"><a class="el" href="../../d7/dc1/structBloomberg_1_1quantum_1_1ICoroPromise.html">ICoroPromise</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.8.15 </li>
  </ul>
</div>
</body>
</html>
